a=0
b=1
for i in range(1,21):
	b*=i
	a+=b
print a